<?php
session_start();
/**
* @package		ReservatieComponent voor ouderavonden van Atheneum Alicebourg Lanaken.
* @copyright	Copyright (C) 2008 Kristof Beckers. All rights reserved.
* @Version		1.0
* @license		GNU/GPL, see LICENSE.php
**/
include ("../../include/header.php");
?>

<head>
<link rel="stylesheet" href="../../css/template_css.css" type="text/css"/> 
</head>
<body>
<div align="center"><img src="<?php echo "../$logo" ; ?>" /><br><br>
<a href="../index.php"/><img src="<?php echo "../$home" ; ?>" border="0"/></a><br><br>

<p>
  <?php 

include ("../../include/config.php");
require_once ("../../include/db.php");
include ("../../include/header.php");

if(isset($_SESSION['myusername'])){
	if ($_SESSION['admin'] == "$adminid") {


$sqldate= "SELECT * FROM $tbparam";
$resdate = mysql_query($sqldate);
while ($rowdate = mysql_fetch_array($resdate)) {
		$datum = $rowdate['datum'];
		}

$date=$_GET['date'];
if ($date == ''){
echo " Selecteer de datum waarop de inschrijving moet gedaan worden. <br /><br />
<a href='?date=$datum'/>$datum</a>";
}
else{
?>
<form name="form1" method="post" action="admres1.php">
  
   <table width="100%" border="0" cellspacing="0" cellpadding="0">
     <tr>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '1%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '2%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '3%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '4%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '5%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '6%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
       <td valign="top"><?php $sql="SELECT DISTINCT klas FROM $tbusers WHERE klas like '7%' ORDER BY klas " ;
  $result=mysql_query($sql);
  echo "<table>";
  while ($row= mysql_fetch_assoc($result)){
  $klas = $row['klas'];
  
  echo " <tr><td><a href='admres1.php?date=$date&klas=$klas' /> $klas </a></td></tr>";
  }
echo "</table>";
  ?></td>
     </tr>
   </table>
   <p>&nbsp;</p>
   <p>

     
     
   </p>
</form>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>
  

 <?php 
 }}}
 
 ?> 
</p></div>
</body>